#ifndef RESOLVER_H
#define RESOLVER_H

#include <string>
#include <map>
#include <queue>

const int c_startingIndex = 1000;

class Logger;
class Request;
class Threads;

//TODO Sameer 
class Resolver
{

	friend class Threads;

public:
	//Resolver( Logger&, std::string );
	Resolver( Logger& , Logger& , std::string c_Res );

	bool ParseResolveFile();
	bool CreateSystemFiles();
	bool Enque( Request* );


private:
	void		PrintResolver();
	Request*	GetReq();
	bool 		Resolve( Request* );
	void		AddEntry( Request* );

	std::multimap< std::string,int >	m_ResolveMap;
	std::string					m_strResFile;
	std::queue< Request* >		m_queue;
	int							currentIndex;

	Logger&					LOGGER;
	Logger&					ERRLOGGER;
};
#endif
